package com.hello.service.impl;

import com.hello.mapper.UserMapper;
import com.hello.pojo.User;
import com.hello.service.UserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class UserServiceImpl implements UserService {

    @Autowired
    private UserMapper userMapper;

    @Override
    public User selectUser(Integer id) {
        return userMapper.selectById(id);
    }

    @Override
    public List<User> selectAllUsers() {
        return userMapper.selectList(null);
    }

    @Override
    public int deleteUser(Integer id) {
        return 0;
    }
}
